// expressjwt中间件
const { expressjwt: jwt } = require("express-jwt");
var secret = 'secretkey!!!'
const jwtAuth = jwt({
    secret,
    credentialsRequired: true,
    algorithms: ["HS256"],
}).unless({
    // 这里是不需要验证的路由
    path:["/users/del/:id","/users/login","/users/list","/users/register", "/upload"]
});

module.exports = jwtAuth;